package com.example.vo;

import lombok.Builder;
import lombok.Data;

import java.util.List;

/**
 * 分页查询
 * @param <T>
 */
@Data
@Builder
public class PageResult<T> {
    private int page;
    private int total;
    private List<T> data;

    public PageResult(int total, List<T> data) {
        this.total = total;
        this.data = data;
    }

    public PageResult(int page, int total, List<T> data) {
        this.page = page;
        this.total = total;
        this.data = data;
    }
}
